<?php

/**
 * Tabela de Sub menu.
 *
 * @author Fernando Dias Oliveira <rodox17@gmail.com>
 * @package intranet
 * @subpackage model
 */

class INT003 extends Zend_Db_Table_Abstract  
{
	protected $_table = "INT003";
	protected $_primary = "INT003_cod";

	/**
	 * Metodo que retorna um array com todos sub menus do banco.
	 * 
	 * @access public
	 * @return array
	 */
	
	public function getMenuSubMenu()
	{
		$db = $this->getAdapter();
		
		$query = "SELECT *
				FROM INT003, INT002
				WHERE INT003_cod_menu = INT002_cod
				LIMIT 0 , 30";
		
		return $db->fetchAll($query);
		
	}
	
	public function getSubMenu()
	{
		$db = $this->getAdapter();
		
		return $this->fetchAll();
	}
}

?>
